package com.szpt.mo.bhubackground.entity.parameters;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class P_Login {

    @Email
    @NotBlank(message = "账号不能为空")
    @ApiModelProperty(value = "账号")
    private String account;

    @NotBlank(message = "密码不能为空")
    @Length(max = 32,min = 6,message = "密码不能短于6位，长于32位")
    @ApiModelProperty(value = "密码")
    private String password;

    @NotBlank(message = "验证码不能为空")
    @Length(max = 6,min = 4,message = "验证码太长或太短")
    @ApiModelProperty(value = "验证码")
    private String code;

}
